load("//tools/build_defs/oss:rn_defs.bzl", "ANDROID", "APPLE", "react_native_xplat_target", "rn_xplat_cxx_library")

rn_xplat_cxx_library(
    name = "jscallinvoker",
    srcs = [
        "jsireact/BridgeJSCallInvoker.cpp",
    ],
    header_namespace = "",
    exported_headers = {
        "jsireact/BridgeJSCallInvoker.h": "jsireact/BridgeJSCallInvoker.h",
        "jsireact/JSCallInvoker.h": "jsireact/JSCallInvoker.h",
    },
    compiler_flags = [
        "-fexceptions",
        "-frtti",
        "-std=c++14",
        "-Wall",
    ],
    platforms = (ANDROID, APPLE),
    preferred_linkage = "static",
    preprocessor_flags = [
        "-DLOG_TAG=\"ReactNative\"",
        "-DWITH_FBSYSTRACE=1",
    ],
    visibility = [
        "PUBLIC",
    ],
    deps = [
        react_native_xplat_target("cxxreact:bridge"),
    ],
)
